//
//  ProfileModel.swift
//  VoiceRoom
//
//  Created by Rae on 2024/3/15.
//

import Foundation

enum VRProfileModel: Equatable {
    case none
    case black, terms, privacy, delete, clear, version
    case avatar, name, gender, age
            
    var title: String {
        switch self {
        case .black:
            return "Blacklist"
        case .terms:
            return "Terms Of Use"
        case .privacy:
            return "Privacy Policy"
        case .delete:
            return "Delete Account"
        case .clear:
            return "Clear Cache"
        case .version:
            return "Version"
        case .avatar:
            return "Avatar"
        case .name:
            return "Nickname"
        case .gender:
            return "Gender"
        case .age:
            return "Age"
        default:
            return ""
        }
    }
    
    var isShowRightImageView: Bool{
        switch self {
        case .terms, .privacy, .delete, .black:
            return true
        default:
            return false
        }
    }
    
    var content: String {
        switch self {
        case .version:
            let version = Bundle.main.infoDictionary?["CFBundleShortVersionString"] as? String
            return "V \(version ?? "")"
        case .clear:
            return String(format: "%.2fMB", FJGlobalTools.shared.queryCacheSize())
        default:
            return ""
        }
    }
}
